<?php
/**
 * Created by LíJimpéy(：
 * User: jimpey88
 * Date: 2024/3/26
 * Email: < jimpey@qq.com >
 * Project: company-admin-tp6
 */

declare (strict_types = 1);

namespace app\backend_api\controller;

use app\BaseController;
use app\common\Utils\Captcha;
use Exception;

class getCaptcha extends BaseController
{
    /**
     * 获取图形验证码
     * @throws Exception
     */
    public function index(Captcha $cap): \think\response\Json
    {
        return $this->success($cap->create());
    }
}
